﻿<%@ page language="java" import="java.util.*" pageEncoding="UTF-8"%>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<%@ taglib prefix="fn" uri="http://java.sun.com/jsp/jstl/functions" %>
<%
String path = request.getContextPath();
String basePath = request.getScheme()+"://"+request.getServerName()+":"+request.getServerPort()+path+"/";
%>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>南京化工职业技术学院资源共享平台--主页</title>
<link href="<%=basePath%>res/css/css.css" type="text/css" rel="stylesheet" />
<script type="text/javascript">
	function checkUpload() {
		if(${user == null}) {
			alert("请在登录后上传文件！");
			<%
				//0 is default share type
				session.setAttribute("shareType", "0");
			%>
			window.location.href="<%=basePath%>login.jsp?refreshurl=upload.jsp";
		} else {
			window.location.href="<%=basePath%>upload.jsp";
		}
	}
	
	function changest(value) {
		if(value == 0) {
			document.getElementById("rn").style.fontWeight="bold";
			document.getElementById("rp").style.fontWeight="";
		}
		if(value == 1) {
			document.getElementById("rp").style.fontWeight="bold";
			document.getElementById("rn").style.fontWeight="";
		}
		var querytype = document.getElementById("querytype");
		querytype.value = value;
	}
	function search() {
		var query = document.getElementById("querytype");
		if(query.value == null || query.value == "") {
			alert("请填写搜索条件！");
			return false;
		}
		return true;
	}
	function changeCourseQuery(value) {
		if(value == 0) {
			document.getElementById("courseName").style.fontWeight="bold";
			document.getElementById("courseTeacher").style.fontWeight="";
		}
		if(value == 1) {
			document.getElementById("courseTeacher").style.fontWeight="bold";
			document.getElementById("courseName").style.fontWeight="";
		}
		var courseQueryType = document.getElementById("courseQueryType");
		courseQueryType.value = value;
	}
	function searchCourse() {
		var query = document.getElementById("courseQuery");
		if(query.value == null || query.value == "") {
			alert("请填写搜索条件！");
			return false;
		}
		return true;
	}
</script>
</head>
<body>
<div id="header">
   <div id="top">
       <ul>
            <li><marquee onmouseover=this.stop() onmouseout=this.start()>今日访问：${accessCount }&nbsp;&nbsp;共享资源总数：${resCount }&nbsp;&nbsp;注册用户总数：${userCount }&nbsp;&nbsp;资源共享达人：${daUser.realName }&nbsp;&nbsp;资源下载热度：${faRes.name }</marquee></li>
       </ul>
   </div>
   <div id="bottom">
       <div id="bleft"><a href="javascript:checkUpload();"><img src="<%=basePath%>res/images/share_05.jpg" width="387" height="65" /></a>
       </div>
       <div id="bright">
            <ul>
            	<c:if test="${empty user}">
                 <li><a href="javascript:window.location.href='<%=basePath%>login.jsp?refreshurl=entry.jsp';"><img src="<%=basePath%>res/images/share_08.jpg" width="31" height="18" /></a>&nbsp;&nbsp;
                 	<a href="javascript:window.location.href='<%=basePath%>register.jsp?refreshurl=entry.jsp';"><img src="<%=basePath%>res/images/share_1.jpg" width="31" height="18" /></a>&nbsp;&nbsp;
                 	<a href="javascript:window.location.href='<%=basePath%>retrieve.jsp';">忘记密码？</a>
                 </li>
                 </c:if>
            	<c:if test="${!empty user}">
                 <li>
                 	<h2>${user.realName }，欢迎回来！</h2><h2><a href="<%=basePath%>njcc/loadUserInfo.action" style="color:red;">个人中心，</a></h2>&nbsp;&nbsp;<h2><a href="<%=basePath%>njcc/logout.action">点击退出！</a></h2>
                 </li>
                 </c:if>
            </ul>
       </div>
   </div>
</div>
<div id="content">
     <div id="cleft">
          <div id="sc"><a href="javascript:checkUpload();"><img src="<%=basePath%>res/images/share_03.jpg" width="192" height="58" /></a>
          </div>
          <div id="dh">
                <div id="dhtop"></div>
                <div id="dhc">
                    <ul>
                    	<c:choose>
                    		<c:when test="${empty types}">
                        		<h1 class="font1">暂无数据</h1>
                    		</c:when>
                    		<c:otherwise>
                    			<c:forEach items="${types}" var="typesObj" varStatus="i">
                    				<div style="height:10px;"></div>
                        			<h1 class="font1"><a href="<%=basePath%>njcc/loadRes.action?type=${typesObj.id }">${typesObj.name }</a></h1>
                        			<c:if test="${i.index == 0}">
                        				<c:choose>
				                    		<c:when test="${empty typelist1}">
				                        		<li class="font1">暂无数据</li>
				                    		</c:when>
				                    		<c:otherwise>
				                    			<c:forEach items="${typelist1}" var="typelist1Obj" varStatus="j">
				                    				<c:if test="${j.index % 2 == 0}">
				                    					<li><div style="width:60px;float:left;"><a href="<%=basePath%>njcc/loadRes.action?type=${typelist1Obj.id }">${typelist1Obj.name }</a></div>|
				                    				</c:if>
				                    				<c:if test="${j.index % 2 != 0}">
				                    					<div style="width:60px;float:right;padding-right:20px;"><a href="<%=basePath%>njcc/loadRes.action?type=${typelist1Obj.id }">${typelist1Obj.name }</a></li>
				                    				</c:if>
				                    			</c:forEach>
				                    		</c:otherwise>
                        				</c:choose>
                        			</c:if>
                        			<c:if test="${i.index == 1}">
                        				<c:choose>
				                    		<c:when test="${empty typelist2}">
				                        		<li class="font1">暂无数据</li>
				                    		</c:when>
				                    		<c:otherwise>
				                    			<c:forEach items="${typelist2}" var="typelist1Obj" varStatus="j">
				                    				<c:if test="${j.index % 2 == 0}">
				                    					<li><div style="width:60px;float:left;"><a href="<%=basePath%>njcc/loadRes.action?type=${typelist1Obj.id }">${typelist1Obj.name }</a></div>|
				                    				</c:if>
				                    				<c:if test="${j.index % 2 != 0}">
				                    					<div style="width:60px;float:right;padding-right:20px;"><a href="<%=basePath%>njcc/loadRes.action?type=${typelist1Obj.id }">${typelist1Obj.name }</a></li>
				                    				</c:if>
				                    			</c:forEach>
				                    		</c:otherwise>
                        				</c:choose>
                        			</c:if>
                        			<c:if test="${i.index == 2}">
                        				<c:choose>
				                    		<c:when test="${empty typelist3}">
				                        		<li class="font1">暂无数据</li>
				                    		</c:when>
				                    		<c:otherwise>
				                    			<c:forEach items="${typelist3}" var="typelist1Obj" varStatus="j">
				                    				<c:if test="${j.index % 2 == 0}">
				                    					<li><div style="width:60px;float:left;"><a href="<%=basePath%>njcc/loadRes.action?type=${typelist1Obj.id }">${typelist1Obj.name }</a></div>|
				                    				</c:if>
				                    				<c:if test="${j.index % 2 != 0}">
				                    					<div style="width:60px;float:right;padding-right:20px;"><a href="<%=basePath%>njcc/loadRes.action?type=${typelist1Obj.id }">${typelist1Obj.name }</a></li>
				                    				</c:if>
				                    			</c:forEach>
				                    		</c:otherwise>
                        				</c:choose>
                        			</c:if>
                        			<c:if test="${i.index == 3}">
                        				<c:choose>
				                    		<c:when test="${empty typelist4}">
				                        		<li class="font1">暂无数据</li>
				                    		</c:when>
				                    		<c:otherwise>
				                    			<c:forEach items="${typelist4}" var="typelist1Obj" varStatus="j">
				                    				<c:if test="${j.index % 2 == 0}">
				                    					<li><div style="width:60px;float:left;"><a href="<%=basePath%>njcc/loadRes.action?type=${typelist1Obj.id }">${typelist1Obj.name }</a></div>|
				                    				</c:if>
				                    				<c:if test="${j.index % 2 != 0}">
				                    					<div style="width:60px;float:right;padding-right:20px;"><a href="<%=basePath%>njcc/loadRes.action?type=${typelist1Obj.id }">${typelist1Obj.name }</a></li>
				                    				</c:if>
				                    			</c:forEach>
				                    		</c:otherwise>
                        				</c:choose>
                        			</c:if>
                        			<c:if test="${i.index == 4}">
                        				<c:choose>
				                    		<c:when test="${empty typelist5}">
				                        		<li class="font1">暂无数据</li>
				                    		</c:when>
				                    		<c:otherwise>
				                    			<c:forEach items="${typelist5}" var="typelist1Obj" varStatus="j">
				                    				<c:if test="${j.index % 2 == 0}">
				                    					<li><div style="width:60px;float:left;"><a href="<%=basePath%>njcc/loadRes.action?type=${typelist1Obj.id }">${typelist1Obj.name }</a></div>|
				                    				</c:if>
				                    				<c:if test="${j.index % 2 != 0}">
				                    					<div style="width:60px;float:right;padding-right:20px;"><a href="<%=basePath%>njcc/loadRes.action?type=${typelist1Obj.id }">${typelist1Obj.name }</a></li>
				                    				</c:if>
				                    			</c:forEach>
				                    		</c:otherwise>
                        				</c:choose>
                        			</c:if>
                    			</c:forEach>
                    		</c:otherwise>
                    	</c:choose>
                  </ul>
                </div>
                <div id="dhbottom"><img src="<%=basePath%>res/images/left_08.jpg" width="192" height="16" />
                </div>
          </div>
     <div id="pm">
                <div id="dhtop"><img src="<%=basePath%>res/images/share_10.jpg" width="192" height="64" /></div>
                <div id="pmc" style="background:#eff8fe;">
                    <ul>
                    	<c:choose>
                    		<c:when test="${empty favRes}">
                    			暂无数据
                    		</c:when>
                    		<c:otherwise>
                    			<c:forEach items="${favRes}" var="favResObj" varStatus="i">
                        			<li><div style="float:left;width:20px;">${i.index+1 }、</div>
                        			<div style="float:left;width:110px;">
		                                              	<c:choose>
		                                              		<c:when test="${fn:length(favResObj.info.name) > 10}">
		                                              			<a href="<%=basePath%>njcc/loadResItem.action?id=${favResObj.info.id }" onmousemove="this.title='${avResObj.info.name }'">${fn:substring(favResObj.info.name,0,8)}..</a>
		                                              		</c:when>
		                                              		<c:otherwise>
		                                              			<a href="<%=basePath%>njcc/loadResItem.action?id=${favResObj.info.id }" onmousemove="this.title='${avResObj.info.name }'">${favResObj.info.name }</a>
		                                              		</c:otherwise>
		                                              	</c:choose>
                        			</div>
                        			${favResObj.info.downloadCount }次</li>
                    			</c:forEach>
                    		</c:otherwise>
                    	</c:choose>
                    </ul>
                </div>
                <div id="dhbottom"><img src="<%=basePath%>res/images/share_12.jpg" width="192" height="16" />
                </div>
       </div>
     <div id="pm">
                <div id="dhtop"><img src="<%=basePath%>res/images/share_12.png" width="192" height="64" /></div>
                <div id="pmc" style="background:#eff8fe;">
                    <ul>
                    	<c:choose>
                    		<c:when test="${empty drusers}">
                    			暂无数据
                    		</c:when>
                    		<c:otherwise>
                    			<c:forEach items="${drusers}" var="drusersObj" varStatus="i">
                        			<li><div style="float:left;width:20px;">${i.index+1 }、</div>
                        			<div style="float:left;width:110px;">
		                                              	<c:choose>
		                                              		<c:when test="${fn:length(drusersObj.realName) > 3}">
		                                              			<a href="<%=basePath%>njcc/loadResItem.action?id=${drusersObj.realName}">${fn:substring(drusersObj.realName,0,3)}</a>
		                                              		</c:when>
		                                              		<c:otherwise>
		                                              			<a href="<%=basePath%>njcc/loadResItem.action?id=${drusersObj.realName }">${drusersObj.realName }</a>
		                                              		</c:otherwise>
		                                              	</c:choose>
                        			</div>
                        			${drusersObj.shareCount }个</li>
                    			</c:forEach>
                    		</c:otherwise>
                    	</c:choose>
                    </ul>
                </div>
                <div id="dhbottom"><img src="<%=basePath%>res/images/share_12.jpg" width="192" height="16" />
                </div>
       </div>
     </div>
<div id="cright">
                <div id="sarch">
                      <ul>
                            <li class="font1" style="padding-top:10px;"><a href="javascript:changest(0);" id="rn" style="font-weight:bold;">资源名称</a>&nbsp;&nbsp;|&nbsp;&nbsp;<a href="javascript:changest(1);" id="rp">分享人</a></li>
                            <li style="padding-top:10px;">
                            	<form action="<%=basePath%>njcc/search.action" method="post" onsubmit="javascript:return search();">
                            		<table>
                            			<tr>
                            				<td>
	                            				<input type="hidden" name="querytype" id="querytype" value="0"/>
	                            				<input type="text" name="query" id="query" class="inputs" />
                            				</td>
                            				<td  style="padding-left:10px;">
	                            				<input name="search" value="" type="submit" class="buttons" />
                            				</td>
                            			</tr>
	                            	</table>
                            	</form>
                        	</li>
                      </ul>
    			</div>
                <div id="tjzy">
                    <div id="wz">
                        <ul>
                            <li>推</li>
                            <li>荐</li>
                            <li>资</li>
                            <li>源</li>
                        </ul>
                    </div>
                    <div id="lb">
                           		<c:choose>
                           			<c:when test="${empty recmdRes}">
	                           			<div id="lb1">
	                           				<ul>
	                           					<li>暂无数据</li>
	                           				</ul>
	                           			</div>
                           			</c:when>
                           			<c:otherwise>
                           				<c:forEach items="${recmdRes}" var="recmdResObj">
		                           			<div id="lb1" style="width:160px;padding-top:10px;">
	                           					<ul>
		                           					<c:if test="${recmdResObj.info.iconUrl == null}">
		                           						<li><a href="<%=basePath%>njcc/loadResItem.action?id=${recmdResObj.info.id }" ><img src="<%=basePath%>res/images/no.gif" width="137" height="96" /></a></li>
		                           					</c:if>
		                           					<c:if test="${recmdResObj.info.iconUrl != null}">
		                           						<li><a href="<%=basePath%>njcc/loadResItem.action?id=${recmdResObj.info.id }" ><img src="<%=basePath%>${recmdResObj.info.iconUrl}" width="137" height="96" /></a></li>
		                           					</c:if>
		                                    		<li class="font2">
		                                              	<c:choose>
		                                              		<c:when test="${fn:length(recmdResObj.info.name) > 10}">
		                                              			<a onmousemove="this.title='${recmdResObj.info.name }'">${fn:substring(recmdResObj.info.name,0,8)}..</a>
		                                              		</c:when>
		                                              		<c:otherwise>
		                                              			<a onmousemove="this.title='${recmdResObj.info.name }'">${recmdResObj.info.name }</a>
		                                              		</c:otherwise>
		                                              	</c:choose>
		                                    		</li>
		                                    		<li>
		                                    		&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
		                                              	<c:choose>
		                                              		<c:when test="${fn:length(recmdResObj.info.summary) > 30}">
		                                              			<a onmousemove="this.title='${recmdResObj.info.summary }'">${fn:substring(recmdResObj.info.summary,0,28)}..</a>
		                                              		</c:when>
		                                              		<c:otherwise>
		                                              			<a onmousemove="this.title='${recmdResObj.info.summary }'">${recmdResObj.info.summary }</a>
		                                              		</c:otherwise>
		                                              	</c:choose>
		                                    		</li>
		                                    		<li><span class="font2"><a onmousemove="this.title='${recmdResObj.userName }'">${fn:substring(recmdResObj.userName, 0, 3)}</a></span>上传于<span class="font3">${recmdResObj.uploadTime}</span></li>
	                                    		</ul>
		                           			</div>
                           				</c:forEach>
                           			</c:otherwise>
                           		</c:choose>
                    </div>
                </div>
             <c:choose>
               <c:when test="${empty types}">
               </c:when>
               <c:otherwise>
                <c:forEach items="${types}" var="typesObj" varStatus="i">
                <div id="jxzy">
                       <div id="bt1">
                             <div id="jx">
                                <ul>
                                   <li class="font4"><a href="<%=basePath%>njcc/loadRes.action?type=${typesObj.id }">${typesObj.name }</a></li>
                               	</ul>
                             </div>
                             <div id="gd">
                                  <ul>
                                       <li><a href="<%=basePath%>njcc/loadRes.action?type=${typesObj.id }">更多&nbsp;&nbsp;>></a></li>
                                  </ul>
                             </div>
                       </div>
                       <c:if test="${i.index == 0}">
                       <div id="pl">
                       	<c:choose>
				            <c:when test="${empty list1}">
				            </c:when>
				       		<c:otherwise>
					            <c:forEach items="${list1}" var="listObj" varStatus="j">
					                <c:if test="${j.index % 5 == 0}">
		                             <div id="pl1">
		                                  <div id="plsm">
		                                       <div id="tup">
		                                       	<c:if test="${empty listObj.info.iconUrl}">
		                                       		<a href="<%=basePath%>njcc/loadResItem.action?id=${listObj.info.id }" ><img src="<%=basePath %>res/images/no.gif" width="137" height="97" /></a>
		                                       	</c:if>
		                                       	<c:if test="${!empty listObj.info.iconUrl}">
		                                       		<a href="<%=basePath%>njcc/loadResItem.action?id=${listObj.info.id }" ><img src="<%=basePath %>${listObj.info.iconUrl }" width="137" height="97" /></a>
		                                       	</c:if>
		                                       </div>
		                                       <div id="wenzi" style="width:180px;">
		                                            <ul>
		                                              <li class="font5"><a onmousemove="this.title='${listObj.info.name }'">${fn:substring(listObj.info.name,0,12) }</a></li>
		                                              <li><span class="font3"><a onmousemove="this.title='${listObj.userName }'">${fn:substring(listObj.userName, 0, 3) }</a></span>上传于<span class="font3">${listObj.uploadTime }</span></li>
		                                              <li>
		                                              	<c:choose>
		                                              		<c:when test="${fn:length(listObj.info.summary) > 30}">
		                                              			<a onmousemove="this.title='${listObj.info.summary }'">${fn:substring(listObj.info.summary,0,28)}...</a>
		                                              		</c:when>
		                                              		<c:otherwise>
		                                              			<a onmousemove="this.title='${listObj.info.summary }'">${listObj.info.summary }</a>
		                                              		</c:otherwise>
		                                              	</c:choose>
		                                              </li>
		                                         </ul>
		                                       </div>
		                                  </div>
					                </c:if>
					                <c:if test="${j.index == 1 || j.index == 6}">
		                                 <div id="plxm">
		                                    <ul>
                                         		<li><img src="<%=basePath %>res/images/share_31.jpg" width="13" height="13" />&nbsp;<span class="font3"><a href="<%=basePath%>njcc/loadResItem.action?id=${listObj.info.id }" >${fn:substring(listObj.info.name, 0, 10) }</a></span>&nbsp;&nbsp;&nbsp;${fn:substring(listObj.userName, 0, 3) }&nbsp;&nbsp;&nbsp;<span class="font3">${listObj.uploadTime }</span></li>
					                </c:if>
					                <c:if test="${j.index == 2 || j.index == 3 || j.index == 7 || j.index == 8}">
                                         <li><img src="<%=basePath %>res/images/share_31.jpg" width="13" height="13" />&nbsp;<span class="font3"><a href="<%=basePath%>njcc/loadResItem.action?id=${listObj.info.id }" >${fn:substring(listObj.info.name, 0, 10) }</a></span>&nbsp;&nbsp;&nbsp;${fn:substring(listObj.userName, 0, 3) }&nbsp;&nbsp;&nbsp;<span class="font3">${listObj.uploadTime }</span></li>
					                </c:if>
					                <c:if test="${j.index == 4 || j.index == 9}">
                                         		<li><img src="<%=basePath %>res/images/share_31.jpg" width="13" height="13" />&nbsp;<span class="font3"><a href="<%=basePath%>njcc/loadResItem.action?id=${listObj.info.id }" >${fn:substring(listObj.info.name, 0, 10) }</a></span>&nbsp;&nbsp;&nbsp;${fn:substring(listObj.userName, 0, 3) }&nbsp;&nbsp;&nbsp;<span class="font3">${listObj.uploadTime }</span></li>
                                         	</ul>
                                         </div>
                                         </div>
					                </c:if>
					             </c:forEach>
					             <%
					             	List list1 = (List)request.getAttribute("list1");
					             	if(list1 != null) {
					             		if(list1.size() < 5 || (list1.size() > 5 && list1.size() < 10)) {
					             			%>
                                         	</ul>
                                         </div>
                                         </div>
					             			<%
					             		}
					             	}
					             %>
				        	</c:otherwise>
                       	 </c:choose>
                        </c:if>
                        
                       <c:if test="${i.index == 1}">
                       <div id="pl">
                       	<c:choose>
				            <c:when test="${empty list2}">
				            </c:when>
				       		<c:otherwise>
					            <c:forEach items="${list2}" var="listObj" varStatus="j">
					                <c:if test="${j.index % 5 == 0}">
		                             <div id="pl1">
		                                  <div id="plsm">
		                                       <div id="tup">
		                                       	<c:if test="${empty listObj.info.iconUrl}">
		                                       		<a href="<%=basePath%>njcc/loadResItem.action?id=${listObj.info.id }" ><img src="<%=basePath %>res/images/no.gif" width="137" height="97" /></a>
		                                       	</c:if>
		                                       	<c:if test="${!empty listObj.info.iconUrl}">
		                                       		<a href="<%=basePath%>njcc/loadResItem.action?id=${listObj.info.id }" ><img src="<%=basePath %>${listObj.info.iconUrl }" width="137" height="97" /></a>
		                                       	</c:if>
		                                       </div>
		                                       <div id="wenzi" style="width:180px;">
		                                            <ul>
		                                              <li class="font5"><a onmousemove="this.title='${listObj.info.name }'">${fn:substring(listObj.info.name,0,12) }</a></li>
		                                              <li><span class="font3"><a onmousemove="this.title='${listObj.userName }'">${fn:substring(listObj.userName, 0, 3) }</a></span>上传于<span class="font3">${listObj.uploadTime }</span></li>
		                                              <li>
		                                              	<c:choose>
		                                              		<c:when test="${fn:length(listObj.info.summary) > 30}">
		                                              			<a onmousemove="this.title='${listObj.info.summary }'">${fn:substring(listObj.info.summary,0,28)}...</a>
		                                              		</c:when>
		                                              		<c:otherwise>
		                                              			<a onmousemove="this.title='${listObj.info.summary }'">${listObj.info.summary }</a>
		                                              		</c:otherwise>
		                                              	</c:choose>
		                                              </li>
		                                         </ul>
		                                       </div>
		                                  </div>
					                </c:if>
					                <c:if test="${j.index == 1 || j.index == 6}">
		                                 <div id="plxm">
		                                    <ul>
                                         		<li><img src="<%=basePath %>res/images/share_31.jpg" width="13" height="13" />&nbsp;<span class="font3"><a href="<%=basePath%>njcc/loadResItem.action?id=${listObj.info.id }" >${fn:substring(listObj.info.name, 0, 10) }</a></span>&nbsp;&nbsp;&nbsp;${fn:substring(listObj.userName, 0, 3) }&nbsp;&nbsp;&nbsp;<span class="font3">${listObj.uploadTime }</span></li>
					                </c:if>
					                <c:if test="${j.index == 2 || j.index == 3 || j.index == 7 || j.index == 8}">
                                         <li><img src="<%=basePath %>res/images/share_31.jpg" width="13" height="13" />&nbsp;<span class="font3"><a href="<%=basePath%>njcc/loadResItem.action?id=${listObj.info.id }" >${fn:substring(listObj.info.name, 0, 10) }</a></span>&nbsp;&nbsp;&nbsp;${fn:substring(listObj.userName, 0, 3) }&nbsp;&nbsp;&nbsp;<span class="font3">${listObj.uploadTime }</span></li>
					                </c:if>
					                <c:if test="${j.index == 4 || j.index == 9}">
                                         		<li><img src="<%=basePath %>res/images/share_31.jpg" width="13" height="13" />&nbsp;<span class="font3"><a href="<%=basePath%>njcc/loadResItem.action?id=${listObj.info.id }" >${fn:substring(listObj.info.name, 0, 10) }</a></span>&nbsp;&nbsp;&nbsp;${fn:substring(listObj.userName, 0, 3) }&nbsp;&nbsp;&nbsp;<span class="font3">${listObj.uploadTime }</span></li>
                                         	</ul>
                                         </div>
                                         </div>
					                </c:if>
					             </c:forEach>
					             <%
					             	List list1 = (List)request.getAttribute("list2");
					             	if(list1 != null) {
					             		if(list1.size() < 5 || (list1.size() > 5 && list1.size() < 10)) {
					             			%>
                                         	</ul>
                                         </div>
                                         </div>
					             			<%
					             		}
					             	}
					             %>
				        	</c:otherwise>
                       	 </c:choose>
                        </c:if>
                        
                       <c:if test="${i.index == 2}">
                       <div id="pl">
                       	<c:choose>
				            <c:when test="${empty list3}">
				            </c:when>
				       		<c:otherwise>
					            <c:forEach items="${list3}" var="listObj" varStatus="j">
					                <c:if test="${j.index % 5 == 0}">
		                             <div id="pl1">
		                                  <div id="plsm">
		                                       <div id="tup">
		                                       	<c:if test="${empty listObj.info.iconUrl}">
		                                       		<a href="<%=basePath%>njcc/loadResItem.action?id=${listObj.info.id }" ><img src="<%=basePath %>res/images/no.gif" width="137" height="97" /></a>
		                                       	</c:if>
		                                       	<c:if test="${!empty listObj.info.iconUrl}">
		                                       		<a href="<%=basePath%>njcc/loadResItem.action?id=${listObj.info.id }" ><img src="<%=basePath %>${listObj.info.iconUrl }" width="137" height="97" /></a>
		                                       	</c:if>
		                                       </div>
		                                       <div id="wenzi" style="width:180px;">
		                                            <ul>
		                                              <li class="font5"><a onmousemove="this.title='${listObj.info.name }'">${fn:substring(listObj.info.name,0,12) }</a></li>
		                                              <li><span class="font3"><a onmousemove="this.title='${listObj.userName }'">${fn:substring(listObj.userName, 0, 3) }</a></span>上传于<span class="font3">${listObj.uploadTime }</span></li>
		                                              <li>
		                                              	<c:choose>
		                                              		<c:when test="${fn:length(listObj.info.summary) > 30}">
		                                              			<a onmousemove="this.title='${listObj.info.summary }'">${fn:substring(listObj.info.summary,0,28)}...</a>
		                                              		</c:when>
		                                              		<c:otherwise>
		                                              			<a onmousemove="this.title='${listObj.info.summary }'">${listObj.info.summary }</a>
		                                              		</c:otherwise>
		                                              	</c:choose>
		                                              </li>
		                                         </ul>
		                                       </div>
		                                  </div>
					                </c:if>
					                <c:if test="${j.index == 1 || j.index == 6}">
		                                 <div id="plxm">
		                                    <ul>
                                         		<li><img src="<%=basePath %>res/images/share_31.jpg" width="13" height="13" />&nbsp;<span class="font3"><a href="<%=basePath%>njcc/loadResItem.action?id=${listObj.info.id }" >${fn:substring(listObj.info.name, 0, 10) }</a></span>&nbsp;&nbsp;&nbsp;${fn:substring(listObj.userName, 0, 3) }&nbsp;&nbsp;&nbsp;<span class="font3">${listObj.uploadTime }</span></li>
					                </c:if>
					                <c:if test="${j.index == 2 || j.index == 3 || j.index == 7 || j.index == 8}">
                                         <li><img src="<%=basePath %>res/images/share_31.jpg" width="13" height="13" />&nbsp;<span class="font3"><a href="<%=basePath%>njcc/loadResItem.action?id=${listObj.info.id }" >${fn:substring(listObj.info.name, 0, 10) }</a></span>&nbsp;&nbsp;&nbsp;${fn:substring(listObj.userName, 0, 3) }&nbsp;&nbsp;&nbsp;<span class="font3">${listObj.uploadTime }</span></li>
					                </c:if>
					                <c:if test="${j.index == 4 || j.index == 9}">
                                         		<li><img src="<%=basePath %>res/images/share_31.jpg" width="13" height="13" />&nbsp;<span class="font3"><a href="<%=basePath%>njcc/loadResItem.action?id=${listObj.info.id }" >${fn:substring(listObj.info.name, 0, 10) }</a></span>&nbsp;&nbsp;&nbsp;${fn:substring(listObj.userName, 0, 3) }&nbsp;&nbsp;&nbsp;<span class="font3">${listObj.uploadTime }</span></li>
                                         	</ul>
                                         </div>
                                         </div>
					                </c:if>
					             </c:forEach>
					             <%
					             	List list1 = (List)request.getAttribute("list3");
					             	if(list1 != null) {
					             		if(list1.size() < 5 || (list1.size() > 5 && list1.size() < 10)) {
					             			%>
                                         	</ul>
                                         </div>
                                         </div>
					             			<%
					             		}
					             	}
					             %>
				        	</c:otherwise>
                       	 </c:choose>
                        </c:if>
                        
                       <c:if test="${i.index == 3}">
                       <div id="pl">
                       	<c:choose>
				            <c:when test="${empty list4}">
				            </c:when>
				       		<c:otherwise>
					            <c:forEach items="${list4}" var="listObj" varStatus="j">
					                <c:if test="${j.index % 5 == 0}">
		                             <div id="pl1">
		                                  <div id="plsm">
		                                       <div id="tup">
		                                       	<c:if test="${empty listObj.info.iconUrl}">
		                                       		<a href="<%=basePath%>njcc/loadResItem.action?id=${listObj.info.id }" ><img src="<%=basePath %>res/images/no.gif" width="137" height="97" /></a>
		                                       	</c:if>
		                                       	<c:if test="${!empty listObj.info.iconUrl}">
		                                       		<a href="<%=basePath%>njcc/loadResItem.action?id=${listObj.info.id }" ><img src="<%=basePath %>${listObj.info.iconUrl }" width="137" height="97" /></a>
		                                       	</c:if>
		                                       </div>
		                                       <div id="wenzi" style="width:180px;">
		                                            <ul>
		                                              <li class="font5"><a onmousemove="this.title='${listObj.info.name }'">${fn:substring(listObj.info.name,0,12) }</a></li>
		                                              <li><span class="font3"><a onmousemove="this.title='${listObj.userName }'">${fn:substring(listObj.userName, 0, 3) }</a></span>上传于<span class="font3">${listObj.uploadTime }</span></li>
		                                              <li>
		                                              	<c:choose>
		                                              		<c:when test="${fn:length(listObj.info.summary) > 30}">
		                                              			<a onmousemove="this.title='${listObj.info.summary }'">${fn:substring(listObj.info.summary,0,28)}...</a>
		                                              		</c:when>
		                                              		<c:otherwise>
		                                              			<a onmousemove="this.title='${listObj.info.summary }'">${listObj.info.summary }</a>
		                                              		</c:otherwise>
		                                              	</c:choose>
		                                              </li>
		                                         </ul>
		                                       </div>
		                                  </div>
					                </c:if>
					                <c:if test="${j.index == 1 || j.index == 6}">
		                                 <div id="plxm">
		                                    <ul>
                                         		<li><img src="<%=basePath %>res/images/share_31.jpg" width="13" height="13" />&nbsp;<span class="font3"><a href="<%=basePath%>njcc/loadResItem.action?id=${listObj.info.id }" >${fn:substring(listObj.info.name, 0, 10) }</a></span>&nbsp;&nbsp;&nbsp;${fn:substring(listObj.userName, 0, 3) }&nbsp;&nbsp;&nbsp;<span class="font3">${listObj.uploadTime }</span></li>
					                </c:if>
					                <c:if test="${j.index == 2 || j.index == 3 || j.index == 7 || j.index == 8}">
                                         <li><img src="<%=basePath %>res/images/share_31.jpg" width="13" height="13" />&nbsp;<span class="font3"><a href="<%=basePath%>njcc/loadResItem.action?id=${listObj.info.id }" >${fn:substring(listObj.info.name, 0, 10) }</a></span>&nbsp;&nbsp;&nbsp;${fn:substring(listObj.userName, 0, 3) }&nbsp;&nbsp;&nbsp;<span class="font3">${listObj.uploadTime }</span></li>
					                </c:if>
					                <c:if test="${j.index == 4 || j.index == 9}">
                                         		<li><img src="<%=basePath %>res/images/share_31.jpg" width="13" height="13" />&nbsp;<span class="font3"><a href="<%=basePath%>njcc/loadResItem.action?id=${listObj.info.id }" >${fn:substring(listObj.info.name, 0, 10) }</a></span>&nbsp;&nbsp;&nbsp;${fn:substring(listObj.userName, 0, 3) }&nbsp;&nbsp;&nbsp;<span class="font3">${listObj.uploadTime }</span></li>
                                         	</ul>
                                         </div>
                                         </div>
					                </c:if>
					             </c:forEach>
					             <%
					             	List list1 = (List)request.getAttribute("list4");
					             	if(list1 != null) {
					             		if(list1.size() < 5 || (list1.size() > 5 && list1.size() < 10)) {
					             			%>
                                         	</ul>
                                         </div>
                                         </div>
					             			<%
					             		}
					             	}
					             %>
				        	</c:otherwise>
                       	 </c:choose>
                       	 </div>
                        </c:if>
                        
                       <c:if test="${i.index == 4}">
                       <div id="pl">
                       	<c:choose>
				            <c:when test="${empty list5}">
				            </c:when>
				       		<c:otherwise>
					            <c:forEach items="${list5}" var="listObj" varStatus="j">
					                <c:if test="${j.index % 5 == 0}">
		                             <div id="pl1">
		                                  <div id="plsm">
		                                       <div id="tup">
		                                       	<c:if test="${empty listObj.info.iconUrl}">
		                                       		<a href="<%=basePath%>njcc/loadResItem.action?id=${listObj.info.id }" ><img src="<%=basePath %>res/images/no.gif" width="137" height="97" /></a>
		                                       	</c:if>
		                                       	<c:if test="${!empty listObj.info.iconUrl}">
		                                       		<a href="<%=basePath%>njcc/loadResItem.action?id=${listObj.info.id }" ><img src="<%=basePath %>${listObj.info.iconUrl }" width="137" height="97" /></a>
		                                       	</c:if>
		                                       </div>
		                                       <div id="wenzi" style="width:180px;">
		                                            <ul>
		                                              <li class="font5"><a onmousemove="this.title='${listObj.info.name }'">${fn:substring(listObj.info.name,0,12) }</a></li>
		                                              <li><span class="font3"><a onmousemove="this.title='${listObj.userName }'">${fn:substring(listObj.userName, 0, 3) }</a></span>上传于<span class="font3">${listObj.uploadTime }</span></li>
		                                              <li>
		                                              	<c:choose>
		                                              		<c:when test="${fn:length(listObj.info.summary) > 30}">
		                                              			<a onmousemove="this.title='${listObj.info.summary }'">${fn:substring(listObj.info.summary,0,28)}...</a>
		                                              		</c:when>
		                                              		<c:otherwise>
		                                              			<a onmousemove="this.title='${listObj.info.summary }'">${listObj.info.summary }</a>
		                                              		</c:otherwise>
		                                              	</c:choose>
		                                              </li>
		                                         </ul>
		                                       </div>
		                                  </div>
					                </c:if>
					                <c:if test="${j.index == 1 || j.index == 6}">
		                                 <div id="plxm">
		                                    <ul>
                                         		<li><img src="<%=basePath %>res/images/share_31.jpg" width="13" height="13" />&nbsp;<span class="font3"><a href="<%=basePath%>njcc/loadResItem.action?id=${listObj.info.id }" >${fn:substring(listObj.info.name, 0, 10) }</a></span>&nbsp;&nbsp;&nbsp;${fn:substring(listObj.userName, 0, 3) }&nbsp;&nbsp;&nbsp;<span class="font3">${listObj.uploadTime }</span></li>
					                </c:if>
					                <c:if test="${j.index == 2 || j.index == 3 || j.index == 7 || j.index == 8}">
                                         <li><img src="<%=basePath %>res/images/share_31.jpg" width="13" height="13" />&nbsp;<span class="font3"><a href="<%=basePath%>njcc/loadResItem.action?id=${listObj.info.id }" >${fn:substring(listObj.info.name, 0, 10) }</a></span>&nbsp;&nbsp;&nbsp;${fn:substring(listObj.userName, 0, 3) }&nbsp;&nbsp;&nbsp;<span class="font3">${listObj.uploadTime }</span></li>
					                </c:if>
					                <c:if test="${j.index == 4 || j.index == 9}">
                                         		<li><img src="<%=basePath %>res/images/share_31.jpg" width="13" height="13" />&nbsp;<span class="font3"><a href="<%=basePath%>njcc/loadResItem.action?id=${listObj.info.id }" >${fn:substring(listObj.info.name, 0, 10) }</a></span>&nbsp;&nbsp;&nbsp;${fn:substring(listObj.userName, 0, 3) }&nbsp;&nbsp;&nbsp;<span class="font3">${listObj.uploadTime }</span></li>
                                         	</ul>
                                         </div>
                                         </div>
					                </c:if>
					             </c:forEach>
					             <%
					             	List list1 = (List)request.getAttribute("list5");
					             	if(list1 != null) {
					             		if(list1.size() < 5 || (list1.size() > 5 && list1.size() < 10)) {
					             			%>
                                         	</ul>
                                         </div>
                                         </div>
					             			<%
					             		}
					             	}
					             %>
				        	</c:otherwise>
                       	 </c:choose>
                       	 </div>
                        </c:if>
                </div>  
                </c:forEach>
              </c:otherwise>
            </c:choose>   
  </div>
</div>
</div>
</div>
</div>
</div>
</div>
<img src="<%=basePath%>res/images/share_44.jpg" width="900" height="95" />
<div id="footer">
      <div id="kc">
            <div class="kchead">
            </div>
            <div id="kcfooter">
                 <ul class="kccc">
                     <li class="font2" >课程名称</li>
                     <li class="font2" >任课老师</li>
                     <li class="font2" >授课班级</li>
                     <li class="font2" >操作</li>
                 </ul>
                 <ul>
                 	<c:choose>
                 		<c:when test="${empty courselist}">
                 		</c:when>
                 		<c:otherwise>
                 			<c:forEach items="${courselist}" var="courseObj">
		                     <li><a onmousemove="this.title='${courseObj.item.courseName }'">${fn:substring(courseObj.item.courseName,0,10) }</a></li>
		                     <li>${courseObj.teacher }</li>
		                     <li>${courseObj.className }</li>
		                     <li><a href="<%=basePath %>course/lookupCourseDir.action?courseId=${courseObj.item.id }">详情</a></li>
                 			</c:forEach>
                 		</c:otherwise>
                 	</c:choose>
                </ul>
                <ul>
                     <li class="font2" style="width:88%;text-align:right;"><a href="<%=basePath %>njcc/searchCourse.action?courseQueryType=3">>>更多</a></li>
                </ul>               
            </div>
      </div>
      <div id="ssuo">
           <div class="sshead"></div>
           <form action="<%=basePath %>njcc/searchCourse.action" method="post" onsubmit="javascript:searchCourse();">
	            <div id="ssfooter">
	                 <ul style="padding-top: 10px;">
	                     <li><a id="courseName" href="javascript:changeCourseQuery(0);" style="font-weight:bold;">课程名称</a>&nbsp;&nbsp;|&nbsp;&nbsp;<a id="courseTeacher" href="javascript:changeCourseQuery(1);" style="font-weight:normals;">任课教师</a></li>
	                     <li><input type="text" name="courseQuery" id="courseQuery" class="inputss" /><input type="hidden" id="courseQueryType" name="courseQueryType" value="0" /></li>
	                     <li>
	                         <input type="submit" name="button"  value="搜 索" class="bottomss" />
	                     </li>
	                 </ul>
	            </div>
            </form>
      </div>
</div>
<div id="banquan">
           <ul>
                 <li>南京化工职业技术学院--资源共享网 <img src="<%=basePath%>res/images/pic.gif" width="50" height="12" /></li>           
                 <li>诚聘英才 | 友情链接 | 联系我们</li> 
                 <li>版权所有©南京化工职业技术学院 ICP：沪B2-20030192 </li>
  </ul>
</div>
</body>
</html>
